/**
 * 飞控大作业
 *
 * File:        calc_move.h
 * Brief:       无人机运动命令解算 PID闭环
 * Author:      Duan Yuhao
 * Modified:	2022/5/25
 *
 */
#ifndef CALC_MOVE_H
#define CALC_MOVE_H


#ifdef __cplusplus
extern "C" {
#endif


#include "stm32f4xx_hal.h"

#define		 ROLL 	0
#define		 PITCH 	1
#define 	 YAW	2

//
typedef enum
{
   UNNORMAL_IMU = 0,
   NORMAL  = 1,
   UNNORMAL_GROUND = 2

}commu_state_typedef;

typedef enum
{
   UNNORMAL = 0,
   NORMAL  = 1

}battery_state_typedef;

typedef struct
{

	double 		body_angle[3];
	double 		body_omega[3];

	double      battery_value;


	commu_state_typedef commu_state; 	//标志飞机是否正常通讯
	battery_state_typedef battery_state;  //标志飞机电量是否充足

} UAV_para_typedef;


extern  UAV_para_typedef UAV_para;

#ifdef __cplusplus
}
#endif


#endif
